Release 10.1A: OpenEdge Development:
ADM Reference


Position native data type table

The Position Native data type table (table type 1), contains a record for each parameter with a sequence number that matches the ordinal position of the parameter in the call. The value of the parameter is stored in one of the value fields in the native data type of the parameter.

Figure A–1 shows the definition of the native position data type table.

DEFINE TEMP-TABLE ttCallParam NO-UNDO 
    FIELD iParamNo       AS INTEGER 
    FIELD cParamName     AS CHARACTER 
    FIELD cDataType      AS CHARACTER 
    FIELD cIOMode        AS CHARACTER 
    FIELD cCharacter     AS CHARACTER 
    FIELD tDate          AS DATE 
    FIELD lLogical       AS LOGICAL 
    FIELD iInteger       AS INTEGER 
    FIELD dDecimal       AS DECIMAL 
    FIELD aRaw           AS RAW 
    FIELD hHandle        AS HANDLE 
    FIELD rRowid         AS ROWID 
    INDEX pudx IS UNIQUE PRIMARY 
      iParamNo. 

Figure A–1: Position native data type table definition

In Example A–7, the following parameters are added to the ttCallParam temp-table:

The parameter number specified in iParamNo indicates the order in which the parameters are specified. As a result, a RUN statement using these parameters would look something like the code in Example A–8. Note the order in which the parameters appear.

Example A–8: Parameters specified in iParamNo 
DEFINE VARIABLE iVal    AS INTEGER NO-UNDO. 
  DEFINE VARIABLE hHandle AS HANDLE NO-UNDO. 
  iVal = 12. 
  hHandle = ?. 
RUN x.p (INPUT "aaa", INPUT-OUTPUT iVal, OUTPUT hHandle). 


Copyright © 2005 Progress Software Corporation
www.progress.com
Voice: (781) 280-4000
Fax: (781) 280-4095